Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Storyshots: framework option should override package dependency check #1482

Merged
merged 3 commits into from
Jul 24, 2017
Merged

Conversation

ktj
Copy link
Contributor

@ktj ktj commented Jul 18, 2017

Issue:
elderfo/react-native-storybook-loader#26

What I did

In storyshots addon I modified the framework check to make sure framework option overrides dependency check.

How to test

Reproduction project: https://github.com/ktj/storyshots-rp

yarn
yarn test

-> tests fail

remove line 8 form package json -> tests work

I've added 3.1.9 example with latest react-native:
https://github.com/ktj/storyshots-rp/tree/319

I added storyshots with this fix as dependency.

@codecov
Copy link

codecov bot commented Jul 18, 2017

Codecov Report

Merging #1482 into master will decrease coverage by 0.06%.
The diff coverage is 0%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #1482      +/-   ##
==========================================
- Coverage    14.6%   14.54%   -0.07%     
==========================================
  Files         202      202              
  Lines        4655     4649       -6     
  Branches      508      515       +7     
==========================================
- Hits          680      676       -4     
+ Misses       3533     3522      -11     
- Partials      442      451       +9
Impacted Files Coverage Δ
addons/storyshots/src/index.js 0% <0%> (ø) ⬆️
app/react/src/client/preview/client_api.js 39.28% <0%> (-2.76%) ⬇️
addons/info/src/components/Story.js 0% <0%> (ø) ⬆️
app/react/src/client/preview/error_display.js 0% <0%> (ø) ⬆️
addons/knobs/src/components/types/Number.js 8.06% <0%> (ø) ⬆️
app/react/src/client/preview/config_api.js 0% <0%> (ø) ⬆️
addons/knobs/src/components/types/Boolean.js 11.62% <0%> (ø) ⬆️
lib/ui/src/modules/ui/containers/down_panel.js 23.52% <0%> (ø) ⬆️
addons/info/src/components/PropVal.js 0% <0%> (ø) ⬆️
lib/ui/src/modules/ui/libs/filters.js 41.66% <0%> (ø) ⬆️
... and 19 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 35f2846...52b319f. Read the comment docs.

Copy link
Member

@ndelangen ndelangen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I haven't tested, but I think this is a good idea. What about you @tmeasday

@tmeasday tmeasday self-assigned this Jul 19, 2017
Copy link
Member

@shilman shilman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM (but didn't test)!

Copy link
Member

@tmeasday tmeasday left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Makes sense to me apart from the package.json change.

@@ -24,6 +24,7 @@
"@storybook/channels": "file:../../lib/channels",
"@storybook/channel-postmessage": "file:../../lib/channel-postmessage",
"@storybook/react-native": "file:../../app/react-native",
"@storybook/react": "file:../../app/react",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are you just adding this line to prove that the fix works, or does it make sense to have it for the RNV app?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just to prove it works

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok can we drop it then? Thanks!

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sounds like this will be super easy to clear up and merge?

@tmeasday tmeasday merged commit 52b319f into storybookjs:master Jul 24, 2017
@tmeasday
Copy link
Member

Done, Thanks @ktj !

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants